Processors for use in portable information terminals are required to consume lower power. As one of low power technology of the processors, there has been proposed a technique in which a cache memory of SRAMs (Static Random Access Memories) having large stand-by power is replaced with a non-volatile memory having non-volatile elements. For example, MRAMs (Magnetoresistive RAMs) are a memory having three advantages of high rewritability, high-speed read and write performance, and a cell area that allows high integration, among non-volatile memories currently proposed. The MRAMs are excellent in speed compared to other non-volatile memories and also excellent in area efficiency compared to conventional memories. Since the MRAMs can have a larger capacity, the MRAMs are expected to be built in a processor, as a cache memory.
However, compared with the conventional SRAM cache memories, the MRAMs that are thought to operate at high speeds are definitely unreliable in writing and data retention. Moreover, the MRAMs become more unreliable in data retention as a data retention period, required in view of power shut down, lasts several seconds or more.
In order to use the MRAMs as a cache memory, it is required to incorporate an ECC (Error Check and Correct) error correction mechanism for correction of errors due to variation in MRAM devices. However, ECC error correction processing requires ECC incorporation that matches the characteristics of a cache memory, due to large overhead of area and latency.
Initial failure, write failure, retention failure and read failure are four MRAM error factors. When the initial failure originated from device fabrication occurs, data has to be definitely corrected by the ECC. However, the error correction process by the ECC has large area overhead and latency overhead. A redundant bit has to be added to deal with a runtime error.
When an uncorrectable error occurs in the ECC process in the cache memory, irrespective of having the MRAMs, the ECC process is terminated as a fatal error, and thus the running program has to be restarted.